﻿using Project;
using UnityEngine;

public class Rifle : BaseWeapon
{
    public GameObject bulletPrefab; //子弹预制体
    public Transform firePos;    //发射点

    public override string Name => "Rifle";

    protected override void Attack()
    {
        GameObject go = Instantiate(bulletPrefab, firePos.position, firePos.rotation);
        go.GetComponent<BaseBullet>().OnFire(dir);
    }
}
